package Lesson2;

import java.util.Scanner;

public class Exercise6 {

	public static void main(String[] args) {
		
		Scanner sc = new Scanner (System.in);
		System.out.println("Please add a number: ");
	
	int a = sc.nextInt();
	int b = 0;
    int c = 0;
	   System.out.print("0");
		for (int i = 1; i<=a; i++)	{	
		   
		   b += i;
		
		   c = c + 1;  
		   		System.out.print(" + " + c );  }
					
		{			
			System.out.print( " = " + b );  }
	
						
						
		}
	}
	


